import axios from "axios";
import { BuildTypeListItem, ResultMessage } from "../model";
import { CascaderOption } from "element-plus/lib/components/index.js";

export const axiosIns = axios.create({
  timeout: 10000,
  baseURL: "/api",
  headers: {
    "Content-Type": "application/json",
  },
});

export const axiosPost = async <T>(url: string, data?: any) => {
  const res = await axiosIns.post(url, data);
  return res.data as T;
};

